<%@ page language="java" pageEncoding="utf-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="s" uri="http://www.springframework.org/tags" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>山西煤炭现货公路交易系统客户端</title>
<link rel="icon" href="" type="image/x-icon" />
<link rel="shortcut icon" href="" type="image/x-icon" />
<link rel="bookmark" href="" type="image/x-icon" />
<link href="<s:url value="/resources"/>/css/style.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="<s:url value="/resources"/>/js/jquery-1.7.2.min.js"></script>
</head>

<script type="text/javascript">
$(function(){  
   var url = "user/findMenu"
      $.post(url,{menuType:1,pid:''},function(data){ 
        var obj = eval('(' + data + ')');
        var menu ="<ul class=\"nav\">";
        for(var i=0;i<obj.length;i++){           
          menu+="<li><a href="+obj[i].customurl+"?menuid="+obj[i].sysid+" class=\"navLink\" target=\"leftFrame\">"+obj[i].menutitle+"</a></li>";
        }
        menu+="</ul>";
         //alert(menu);
         $("#topmenu").html(menu);
        });
    loadUserInfo();
 }); 
 
 function loadUserInfo(){
     var url = "common/loadUser"
     $.post(url,function(data){
       var json = eval('(' + data + ')');
       //alert(json.orgname+json.rolename+json.username);
       //console.log(json);	
       $("#orgname").html(json.orgname);
       $("#rolename").html(json.rolename);
       $("#username").html(json.username);
       $("#message").html(json.orgname +"    " + json.rolename + "    " +json.username);
     });
 }

</script>

<body>
<div id="topMain">
<div id="topLeft">
<img src="<s:url value="/resources"/>/images/logo1.gif"  border="0" class="logo" />
</div>
<div id="topRight">
<table border="0" cellspace width="100%" cellspacing="0" cellpadding="0" style="border-collapse:collapse;">
<tr>
	<td><div id="topmenu"></div></td>
	<td align="right" colspan="3" valign="top"><a href="#" class="subscribe"  onclick=top.location.replace("login/logout")></a>
	</td>
</tr>
<tr>
	<td height="25px" colspan="2">
	    <div id="message" style="position:relative;left:800px;width:500px;font-size:12px"></div>
	</td>
</tr>
<tr>
<td colspan="2"  height="20px"  >
<font size="2" ><div id="menutitle"></div></font>
<!-- 导航 -->
<input type="hidden" id="flag" value="0" />
 </td>
</tr>
</table>
</div>
</div>

</body>
</html>
